function XSLTCache() {
   this.transformers = {};
}

XSLTCache.prototype.loadTransform = function(name,node)
{
   var processor = new XSLTProcessor();
   processor.importStylesheet(node);
   this.transformers[name] = processor;
}

XSLTCache.prototype.loadTransformFromURI = function(name,uri,async,notify) {
   var cache = this;
   if (async) {
      HTTP("GET",uri,{
         timeout: 2*60*1000,
         overrideMimeType: "text/xml",
         onSuccess: function(status,doc) {
            cache.loadTransform(name,doc);
            if (notify) {
               notify(status);
            }
         },
         onFailure: function(status,doc) {
            if (notify) {
               notify(status);
            }
         }
      });
   } else {
      HTTP("GET",uri,{
         synchronizedRequest: true,
         overrideMimeType: "text/xml",
         onSuccess: function(status,doc) {
            cache.loadTransform(name,doc);
            if (notify) {
               notify(200);
            }
         },
         onFailure: function(status,doc) {
            if (notify) {
               notify(status);
            }
         }
      });
   }
}